package com.iplant.mes.service.po.ipt;

import com.fasterxml.jackson.annotation.JsonProperty;
import com.iplant.base.po.BasePO;
import com.iplant.base.po.enums.DBSchemas;
import com.iplant.base.utils.annotation.po.DBBasePO;
import com.iplant.base.utils.annotation.condition.DBCondition;
import com.iplant.base.utils.annotation.field.DBField;
import com.iplant.base.utils.annotation.join.DBJoin;
import com.iplant.pdm.service.po.bop.partpoint.FPCRouteStep;

import java.util.ArrayList;
import java.util.List;

/**
 * 检验值
 *
 * @author YouWang·Peng
 * 2024-3-10 10:44:33
 */
@DBBasePO(TableName = "ipt_value", Name = false, Active = false, Schemas = DBSchemas.MES,
        CheckName = {"Code", "RoutePartPointID,RouteStepID,TaskID"}, CodeAuto = true, CodePrefix = "IPTV-{yyMMdd}-")
public class IPTValue extends BasePO {
    /**
     * 工艺工序
     */
    @DBCondition
    @DBField
    public int RoutePartPointID = 0;

    @DBJoin(name = "Name", tableName = "fpc_routepartpoint", tableAsName = "fpc_routepartpoint1", Schemas =
            DBSchemas.PDM,
            MainTableField = "RoutePartPointID")
    public String RoutePartPointName = "";

    /**
     * 工艺工步
     */
    @DBCondition
    @DBField
    public int RouteStepID = 0;

    @DBJoin(name = "ComponentType", tableName = "fpc_route_step", tableAsName = "fpc_route_step1", Schemas =
            DBSchemas.PDM,
            MainTableField = "RouteStepID")
    public int ComponentType = 0;

    /**
     * 工艺工步名称
     */
    @DBJoin(name = "WorkContent", tableName = "fpc_route_step", tableAsName = "fpc_route_step1", Schemas =
            DBSchemas.PDM,
            MainTableField = "RouteStepID")
    public String RouteStepName = "";

    /**
     * 是否打印
     */
    @DBCondition
    @DBJoin(name = "IsPrint", tableName = "fpc_route_step", tableAsName = "fpc_route_step1", Schemas =
            DBSchemas.PDM,
            MainTableField = "RouteStepID")
    public int IsPrint = 0;

    @DBCondition
    @DBJoin(name = "StepOrder", tableName = "fpc_route_step", tableAsName = "fpc_route_step1", Schemas =
            DBSchemas.PDM,
            MainTableField = "RouteStepID")
    public int StepOrder = 0;

    /**
     * 是否为首检项
     */
    @DBJoin(name = "IsFirstCheck", tableName = "fpc_route_step", tableAsName = "fpc_route_step1", Schemas =
            DBSchemas.PDM,
            MainTableField = "RouteStepID")
    public int IsFirstCheck = 0;

    /**
     * 填写值
     */
    @DBField
    public String Value = "";
    /**
     * 备注
     */
    @DBField
    public String Remark = "";
    /**
     * 检验结果
     */
    @DBField
    public int Result = 0;
    /**
     * 检验单ID
     */
    @DBCondition(CompareType = DBCondition.DBCompareType.in)
    @DBField
    public int TaskID = 0;
    /**
     * 检验类型
     */
    @DBJoin(name = "Type", tableName = "sfc_task_ipt", tableAsName = "sfc_task_ipt1", Schemas = DBSchemas.MES,
            MainTableField = "TaskID")
    public int TaskType = 0;

    /**
     * 图片路径
     */
    @DBField
    public List<String> ImagePath = new ArrayList<>();
    /**
     * 视频路径
     */
    @DBField
    public List<String> VideoPath = new ArrayList<>();
    /**
     * 厂家
     */
    @DBField
    public String Manufactor = "";
    /**
     * 型号
     */
    @DBField
    public String Modal = "";
    /**
     * 编号
     */
    @DBField
    public String Number = "";
    /**
     * 状态
     */
    @DBCondition(CompareType = DBCondition.DBCompareType.in)
    @DBField
    public int Status = 0;
    /**
     * 拆解部件
     */
    @DBField
    public String DisassemblyComponents = "";
    /**
     * 维修部件
     */
    @DBField
    public String RepairParts = "";
    /**
     * 组装部件
     */
    @DBField
    public String AssemblyParts = "";
    /**
     * 拆解自修件
     */
    @DBField
    public String SRDisassemblyComponents = "";
    /**
     * 维修自修件
     */
    @DBField
    public String SRRepairParts = "";
    /**
     * 组装自修件
     */
    @DBField
    public String SRAssemblyParts = "";
    /**
     * 报废自修件
     */
    @DBField
    public String SRScrapParts = "";
    /**
     * 领用自修件
     */
    @DBField
    public String SRLYParts = "";
    /**
     * 物料ID
     */
    @DBField
    public int MaterialID = 0;
    /**
     * 物料编码
     */
    @DBJoin(name = "Code", tableName = "mss_material", tableAsName = "t1", Schemas = DBSchemas.Basic,
            MainTableField = "MaterialID")
    public String MaterialNo = "";
    /**
     * 物料名称
     */
    @DBJoin(name = "MaterialName", tableName = "mss_material", tableAsName = "t1", Schemas = DBSchemas.Basic,
            MainTableField = "MaterialID")
    public String MaterialName = "";

    /**
     * 工步信息
     */
    public FPCRouteStep RouteStep = new FPCRouteStep();

    /**
     *参数
     */
    @DBJoin(name = "ProductParameter", tableName = "fpc_route_step", tableAsName = "fpc_route_step1", Schemas =
            DBSchemas.PDM,
            MainTableField = "RouteStepID")
    public int ProductParameter=0;

    /**
     * 单位ID
     */
    @DBJoin(name = "UnitID", tableName = "fpc_product_parameter", tableAsName = "fpc_product_parameter1", Schemas
            = DBSchemas.PDM,
            ConditionalJoin = "fpc_product_parameter1.ID=fpc_route_step1.ProductParameter" ,JoinIndex = 2)
    public int UnitID = 0;
    /**
     * 单位名称
     */
    @DBJoin(name = "Name", tableName = "mss_unit", tableAsName = "mss_unit1", Schemas = DBSchemas.Basic,
            ConditionalJoin = "mss_unit1.ID=fpc_product_parameter1.UnitID", JoinIndex = 3)
    public String UnitName = "";
    /**
     * 单位编码
     */
    @DBJoin(name = "Code", tableName = "mss_unit", tableAsName = "mss_unit1", Schemas = DBSchemas.Basic,
            ConditionalJoin = "mss_unit1.ID=fpc_product_parameter1.UnitID", JoinIndex = 3)
    public String UnitCode = "";


    @JsonProperty("RoutePartPointID")
    public int getRoutePartPointID() {
        return RoutePartPointID;
    }

    public void setRoutePartPointID(int routePartPointID) {
        RoutePartPointID = routePartPointID;
    }

    @JsonProperty("RouteStepID")
    public int getRouteStepID() {
        return RouteStepID;
    }

    public void setRouteStepID(int routeStepID) {
        RouteStepID = routeStepID;
    }

    @JsonProperty("Value")
    public String getValue() {
        return Value;
    }

    public void setValue(String value) {
        Value = value;
    }

    @JsonProperty("Remark")
    public String getRemark() {
        return Remark;
    }

    public void setRemark(String remark) {
        Remark = remark;
    }

    @JsonProperty("Result")
    public int getResult() {
        return Result;
    }

    public void setResult(int result) {
        Result = result;
    }

    @JsonProperty("TaskID")
    public int getTaskID() {
        return TaskID;
    }

    public void setTaskID(int taskID) {
        TaskID = taskID;
    }

    @JsonProperty("TaskType")
    public int getTaskType() {
        return TaskType;
    }

    public void setTaskType(int taskType) {
        TaskType = taskType;
    }

    @JsonProperty("ImagePath")
    public List<String> getImagePath() {
        return ImagePath;
    }

    public void setImagePath(List<String> imagePath) {
        ImagePath = imagePath;
    }

    @JsonProperty("VideoPath")
    public List<String> getVideoPath() {
        return VideoPath;
    }

    public void setVideoPath(List<String> videoPath) {
        VideoPath = videoPath;
    }

    @JsonProperty("Manufactor")
    public String getManufactor() {
        return Manufactor;
    }

    public void setManufactor(String manufactor) {
        Manufactor = manufactor;
    }

    @JsonProperty("Modal")
    public String getModal() {
        return Modal;
    }

    public void setModal(String modal) {
        Modal = modal;
    }

    @JsonProperty("Number")
    public String getNumber() {
        return Number;
    }

    public void setNumber(String number) {
        Number = number;
    }

    @JsonProperty("Status")
    public int getStatus() {
        return Status;
    }

    public void setStatus(int status) {
        Status = status;
    }

    @JsonProperty("DisassemblyComponents")
    public String getDisassemblyComponents() {
        return DisassemblyComponents;
    }

    public void setDisassemblyComponents(String disassemblyComponents) {
        DisassemblyComponents = disassemblyComponents;
    }

    @JsonProperty("RepairParts")
    public String getRepairParts() {
        return RepairParts;
    }

    public void setRepairParts(String repairParts) {
        RepairParts = repairParts;
    }

    @JsonProperty("AssemblyParts")
    public String getAssemblyParts() {
        return AssemblyParts;
    }

    public void setAssemblyParts(String assemblyParts) {
        AssemblyParts = assemblyParts;
    }

    @JsonProperty("SRDisassemblyComponents")
    public String getSRDisassemblyComponents() {
        return SRDisassemblyComponents;
    }

    public void setSRDisassemblyComponents(String SRDisassemblyComponents) {
        this.SRDisassemblyComponents = SRDisassemblyComponents;
    }

    @JsonProperty("SRRepairParts")
    public String getSRRepairParts() {
        return SRRepairParts;
    }

    public void setSRRepairParts(String SRRepairParts) {
        this.SRRepairParts = SRRepairParts;
    }

    @JsonProperty("SRAssemblyParts")
    public String getSRAssemblyParts() {
        return SRAssemblyParts;
    }

    public void setSRAssemblyParts(String SRAssemblyParts) {
        this.SRAssemblyParts = SRAssemblyParts;
    }

    @JsonProperty("SRScrapParts")
    public String getSRScrapParts() {
        return SRScrapParts;
    }

    public void setSRScrapParts(String SRScrapParts) {
        this.SRScrapParts = SRScrapParts;
    }

    @JsonProperty("SRLYParts")
    public String getSRLYParts() {
        return SRLYParts;
    }

    public void setSRLYParts(String SRLYParts) {
        this.SRLYParts = SRLYParts;
    }

    @JsonProperty("MaterialID")
    public int getMaterialID() {
        return MaterialID;
    }

    public void setMaterialID(int materialID) {
        MaterialID = materialID;
    }

    @JsonProperty("MaterialNo")
    public String getMaterialNo() {
        return MaterialNo;
    }

    public void setMaterialNo(String materialNo) {
        MaterialNo = materialNo;
    }

    @JsonProperty("MaterialName")
    public String getMaterialName() {
        return MaterialName;
    }

    public void setMaterialName(String materialName) {
        MaterialName = materialName;
    }

    @JsonProperty("ComponentType")
    public int getComponentType() {
        return ComponentType;
    }

    public void setComponentType(int componentType) {
        ComponentType = componentType;
    }

    @JsonProperty("RouteStepName")
    public String getRouteStepName() {
        return RouteStepName;
    }

    public void setRouteStepName(String routeStepName) {
        RouteStepName = routeStepName;
    }

    @JsonProperty("StepOrder")
    public int getStepOrder() {
        return StepOrder;
    }

    public void setStepOrder(int stepOrder) {
        StepOrder = stepOrder;
    }

    @JsonProperty("RoutePartPointName")
    public String getRoutePartPointName() {
        return RoutePartPointName;
    }

    public void setRoutePartPointName(String routePartPointName) {
        RoutePartPointName = routePartPointName;
    }

    @JsonProperty("IsFirstCheck")
    public int getIsFirstCheck() {
        return IsFirstCheck;
    }

    public void setIsFirstCheck(int isFirstCheck) {
        IsFirstCheck = isFirstCheck;
    }

    @JsonProperty("RouteStep")
    public FPCRouteStep getRouteStep() {
        return RouteStep;
    }

    public void setRouteStep(FPCRouteStep routeStep) {
        RouteStep = routeStep;
    }

    @JsonProperty("IsPrint")
    public int getIsPrint() {
        return IsPrint;
    }

    public void setIsPrint(int isPrint) {
        IsPrint = isPrint;
    }

    @JsonProperty("ProductParameter")
    public int getProductParameter() {
        return ProductParameter;
    }

    public void setProductParameter(int productParameter) {
        ProductParameter = productParameter;
    }

    @JsonProperty("UnitID")
    public int getUnitID() {
        return UnitID;
    }

    public void setUnitID(int unitID) {
        UnitID = unitID;
    }

    @JsonProperty("UnitName")
    public String getUnitName() {
        return UnitName;
    }

    public void setUnitName(String unitName) {
        UnitName = unitName;
    }

    @JsonProperty("UnitCode")
    public String getUnitCode() {
        return UnitCode;
    }

    public void setUnitCode(String unitCode) {
        UnitCode = unitCode;
    }
}

